package com.vibration.web.controller.baseinfo;

import com.vibration.baseinfo.domain.CzEquipment;
import com.vibration.baseinfo.domain.CzEquipmentData;
import com.vibration.baseinfo.service.ICzEquipmentDataService;
import com.vibration.common.annotation.Log;
import com.vibration.common.core.controller.BaseController;
import com.vibration.common.core.domain.AjaxResult;
import com.vibration.common.enums.BusinessType;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/baseinfo/equipmentData")
public class CzEquipmentDataController extends BaseController {
    @Autowired
    private ICzEquipmentDataService iCzEquipmentDataService;

    @PreAuthorize("@ss.hasPermi('baseinfo:equipment:add')")
    @Log(title = "设备管理", businessType = BusinessType.INSERT)
    @PostMapping
    public AjaxResult add(@RequestBody CzEquipmentData czEquipmentData )
    {
        return toAjax(iCzEquipmentDataService.insertCzEquipmentData(czEquipmentData));
    }
}
